func flatten<%= resource_name -%>Options(response map[string]interface{}) (map[string]interface{}, error) {
    opts := make(map[string]interface{})
<% first_assign = true -%>
<% properties_to_show(object).each do |prop| -%>
<%   first_assign, c = convert_to_option(prop, 'response, nil', resource_name, first_assign, 'opts', object.name) -%>
<%   unless c.empty? -%>

    <%= c %>
<%   end -%>
<% end -%>

    return opts, nil
}

<% properties_to_show(object).each do |prop| -%>
<%= lines(build_convert_option_method(resource_name, prop, object.name), 1) -%>
<% end -%>
